package com.bootemp.mapper;

import com.bootemp.bean.Dept;
import com.bootemp.bean.SalGrade;
import org.apache.ibatis.annotations.Delete;
import org.apache.ibatis.annotations.Insert;
import org.apache.ibatis.annotations.Select;
import org.apache.ibatis.annotations.Update;

import java.util.List;

public interface SalGradeMapper {
    @Insert(value = "insert into salgrade values(default,#{losal},#{hisal})")
    int insert(SalGrade d);
    @Select(value = "select * from salgrade")
    List<SalGrade> all();
    @Delete(value = "delete from salgrade where grade=#{id}")
    int delete(int id);
    @Select(value = "select * from salgrade where grade=#{id}")
    SalGrade one(int id);
    @Update(value = "update salgrade set losal=#{losal},hisal=#{hisal} where grade=#{grade}")
    int update(SalGrade d);
}
